home *** CD-ROM | disk | FTP | other *** search
/ Micromanía: 150 Juegos 2010 / 150Juegos_16.iso / Shareware / Shape Smash / shape-smash.swf / scripts / Code / LIB / COMPONENTS / _is281.as < prev   
Encoding:
Text File  |  2010-05-14  |  2.7 KB  |  96 lines

  1. package Code.LIB.COMPONENTS
  2. {
  3.    import Code.LIB._dk430;
  4.    import Code.LIB._oo505;
  5.    import Code.LIB._rs402;
  6.    import flash.display.BitmapData;
  7.    import flash.events.Event;
  8.    import flash.geom.Point;
  9.    import flash.geom.Rectangle;
  10.    
  11.    public class _is281 extends _dk430
  12.    {
  13.       private var iBitmaps:Array;
  14.       
  15.       private var iProgress:int;
  16.       
  17.       private var iInd:int;
  18.       
  19.       private var iBitmap:_oo505;
  20.       
  21.       public function _is281(param1:_oo505, param2:_oo505, param3:_oo505)
  22.       {
  23.          var _loc4_:_oo505 = null;
  24.          var _loc5_:_oo505 = null;
  25.          var _loc6_:int = 0;
  26.          var _loc7_:Number = NaN;
  27.          var _loc8_:BitmapData = null;
  28.          var _loc9_:_oo505 = null;
  29.          super();
  30.          _loc4_ = param1;
  31.          _loc5_ = param2;
  32.          this.iBitmaps = new Array();
  33.          this.addChild(_loc5_);
  34.          _loc6_ = 0;
  35.          while(_loc6_ < 100)
  36.          {
  37.             _loc7_ = (_loc6_ + 1) / 100;
  38.             _loc8_ = new BitmapData(_loc4_.bitmapData.width,_loc7_ * _loc4_.bitmapData.height,true,255);
  39.             _loc8_.copyPixels(_loc4_.bitmapData,new Rectangle(0,_loc4_.bitmapData.height - _loc7_ * _loc4_.bitmapData.height,_loc4_.bitmapData.width,_loc7_ * _loc4_.bitmapData.height),new Point(0,0));
  40.             _loc9_ = new _oo505();
  41.             _loc9_.bitmapData = _loc8_;
  42.             _loc9_._vg471 = (_loc4_.bitmapData.height - _loc7_ * _loc4_.bitmapData.height) / _rs402._oy577;
  43.             this.iBitmaps.push(_loc9_);
  44.             _loc6_++;
  45.          }
  46.          this.iBitmap = new _oo505();
  47.          iBitmap._ru276 = _loc4_._ru276;
  48.          iBitmap._ob68 = _loc4_._ob68;
  49.          iBitmap._vq458 = 0;
  50.          iBitmap._vg471 = 0;
  51.          this.addChild(param3);
  52.          this.addChild(iBitmap);
  53.          iProgress = 1;
  54.          iInd = 0;
  55.       }
  56.       
  57.       public function get _wq701() : int
  58.       {
  59.          return this.iInd;
  60.       }
  61.       
  62.       public function get _io94() : int
  63.       {
  64.          return this.iProgress;
  65.       }
  66.       
  67.       override public function onEnterFrame(param1:Event) : void
  68.       {
  69.          if(iProgress != iInd)
  70.          {
  71.             iInd += iInd < iProgress ? 1 : -1;
  72.             iBitmap.bitmapData = _oo505(iBitmaps[iInd - 1]).bitmapData;
  73.             iBitmap._vg471 = _oo505(iBitmaps[iInd - 1])._vg471;
  74.          }
  75.       }
  76.       
  77.       public function set _io94(param1:int) : void
  78.       {
  79.          if(param1 == iProgress)
  80.          {
  81.             return;
  82.          }
  83.          this.iProgress = param1;
  84.          if(iProgress < 0)
  85.          {
  86.             iProgress = 0;
  87.          }
  88.          if(iProgress > 100)
  89.          {
  90.             iProgress = 100;
  91.          }
  92.       }
  93.    }
  94. }
  95.  
  96.